<include file="public@header"/>
</head>
<body>
<div class="wrap js-check-wrap">
    <ul class="nav nav-tabs">
        <li><a href="{:url('Student/index')}">查询学生</a></li>
        <li class="active"><a href="{:url('Student/add_student')}">添加学生</a></li>
    </ul>
    <form action="{:url('Student/add_student_Post')}" method="post" class="form-horizontal margin-top-20">
        <div class="row">
            <div class="col-md-9">
                <table class="table table-bordered">
                    <tr>
                        <th width="140">年级<span class="form-required">*</span></th>
                        <td>
							<div>
								<input class="btn btn-default" style="width:15%;margin:2px" id="1" name="deg_select" type="button" value="一年级" />
								<input class="btn btn-default" style="width:15%;margin:2px" id="2" name="deg_select" type="button" value="二年级" />
								<input class="btn btn-default" style="width:15%;margin:2px" id="3" name="deg_select" type="button" value="三年级" />
								<input class="btn btn-default" style="width:15%;margin:2px" id="4" name="deg_select" type="button" value="四年级" />
								<input class="btn btn-default" style="width:15%;margin:2px" id="5" name="deg_select" type="button" value="五年级" />
								<input class="btn btn-default" style="width:15%;margin:2px" id="6" name="deg_select" type="button" value="六年级" />
							</div>
							<div>
								<input class="btn btn-default" style="width:15%;margin:2px" id="7" name="deg_select" type="button" value="初一" />
								<input class="btn btn-default" style="width:15%;margin:2px" id="8" name="deg_select" type="button" value="初二" />
								<input class="btn btn-default" style="width:15%;margin:2px" id="9" name="deg_select" type="button" value="初三" />
							</div>
							<div>
								<input class="btn btn-default" style="width:15%;margin:2px" id="10" name="deg_select" type="button" value="高一" />
								<input class="btn btn-default" style="width:15%;margin:2px" id="11" name="deg_select" type="button" value="高二" />
								<input class="btn btn-default" style="width:15%;margin:2px" id="12" name="deg_select" type="button" value="高三" />
							</div>
							<input type="hidden" name="deg" required="required" value="{$param['deg']|default=''}" />
                        </td>
                    </tr>
                    <tr>
                        <th>姓名<span class="form-required">*</span></th>
                        <td>
                            <input class="form-control" type="text" name="name"
                                   id="name" required="required" value="{$param['name']|default=''}" placeholder="请输入姓名"/>
                        </td>
                    </tr>
                    <tr>
                        <th>联系方式<span class="form-required">*</span></th>
                        <td>
                            <input class="form-control" type="text" required="required" name="phone" id="phone" value="{$param['phone']|default=''}"
                                   placeholder="请输入联系方式">
                        </td>
                    </tr>
                    <tr>
                        <th>备用联系方式</th>
                        <td><input class="form-control" type="text" name="phone2" id="phone2" value=""
                                   placeholder="请输入备用联系方式"></td>
                    </tr>
					<tr>
                        <th>性别</th>
                        <td>
							<input class="btn btn-default" style="width:39%;margin:0 5% 0 5%" id="man" type="button" value="男" />
							<input class="btn btn-default" style="width:39%;margin:0 5% 0 5%" id="woman" type="button"  value="女" />
						</td>
						<input type="hidden" name="sex" value="{$param['sex']|default=''}" />
                    </tr>
					<tr>
                        <th>身份证号码</th>
                        <td><input class="form-control" type="text" name="IDcard" id="IDcard" value=""
                                   placeholder="请输入身份证号码"></td>
                    </tr>
                    <tr>
                        <th>备注</th>
                        <td>
                            <input class="form-control" name="note" style="height: 50px;"
                                      placeholder="请填写备注信息"></input>
                        </td>
                    </tr>
                </table>
            </div>
            <div class="col-md-3">
                <table class="table table-bordered">
				
                    <tr>
                        <th><b>生日</b></th>
                    </tr>
                    <tr>
                        <td>
                            <input class="form-control js-bootstrap-date" type="text" name="birthday"
                                   value="">
                        </td>
                    </tr>
					
                </table>
            </div>
			<div class="form-group">
				<div class="col-sm-offset-2 col-sm-10">
					<button type="submit" class="btn btn-primary js-ajax-submit">{:lang('ADD')}</button>
					<a class="btn btn-default" href="{:url('Student/index')}">{:lang('BACK')}</a>
				</div>
			</div>
        </div>
    </form>
</div>
<script type="text/javascript" src="__STATIC__/js/admin.js"></script>
<script type="text/javascript">
    //编辑器路径定义
    var editorURL = GV.WEB_ROOT;
</script>
<script type="text/javascript" src="__STATIC__/js/ueditor/ueditor.config.js"></script>
<script type="text/javascript" src="__STATIC__/js/ueditor/ueditor.all.min.js"></script>
<script type="text/javascript">
	$(function(){
		$("#man").click(function(){
			$("#man").prop("class","col-xs-4 col-sm-6 btn btn-success");
			$("#woman").prop("class","col-xs-4 col-sm-6 btn btn-default");
			$("input[name='sex']").val('1');
		});
		$("#woman").click(function(){
			$("#woman").prop("class","col-xs-4 col-sm-6 btn btn-success");
			$("#man").prop("class","col-xs-4 col-sm-6 btn btn-default");
			$("input[name='sex']").val('2');
		});
		$("input[name='deg_select']").click(function(){
			$("input[name='deg_select']").prop("class","btn btn-default");
			$(this).prop("class","btn btn-success");
			var that = $(this).prop("id");
			$("input[name='deg']").val(that);
		});
	});
</script>
</body>
</html>
